#pragma once
#include <boost/signals2/signal.hpp>
#include <nice2d/component.h>

class Selectable : public Component
{
public:
    Selectable(NodePointer object = nullptr);
    ~Selectable();
public:
    void select();
    boost::signals2::signal<void(std::shared_ptr<Component>)> selected;

    void toggleSelected();
    void unselect();
    boost::signals2::signal<void(std::shared_ptr<Component>)> unselected;

    bool isSelected()const;
private:
    std::unique_ptr<class SelectableData> data;
};

